package com.alvis.media.repository;

import com.alvis.media.domain.VideoInfo;
import com.alvis.media.viewmodel.video.VideoPageRequestVM;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * VideoInfo Mapper接口
 */
@Mapper
public interface VideoInfoMapper extends MediaBaseMapper<VideoInfo> {

    /**
     * 视频分页查询
     *
     * @param requestVM 分页请求参数
     * @return List<VideoInfo>
     */
    List<VideoInfo> videoPage(VideoPageRequestVM requestVM);

    /**
     * 根据ID查询视频信息
     *
     * @param videoId 视频ID
     * @return VideoInfo
     */
    VideoInfo selectByVideoId(Integer videoId);

    /**
     * 根据创建者ID查询视频列表
     *
     * @param creatorId 创建者ID
     * @return List<VideoInfo>
     */
    List<VideoInfo> selectByCreatorId(Integer creatorId);
}
